package com.example.elemboot.Dao;

import com.example.elemboot.Entity.User;
import jakarta.transaction.Transactional;
import org.springframework.data.repository.CrudRepository;
import org.springframework.stereotype.Repository;

@Repository
public interface IUser extends CrudRepository<User,Integer> {
    User findUserByUserPhoneAndPassword(String userPhone,String password);
    Boolean existsUserByUserPhone(String phone);
    User findUserByUserPhone(String userPhone);
    @Transactional
    void deleteUserByUserId(Integer id);

}
